package org.chen.wx.controller;

import org.chen.wx.dto.Msg;
import org.chen.wx.utils.WxSendUtils;
import org.springframework.web.bind.annotation.*;

import javax.annotation.Resource;

/**
 * Author:Mr.Chen
 * Date:2018/8/4
 */
@RestController
@RequestMapping(value = "msg")
public class WxMsgController {

    @Resource
    private WxSendUtils wxSendUtils;

    @PostMapping(value = "send")
    public void sendMsg(@RequestBody Msg msg, @RequestParam String token) {
        wxSendUtils.sendMsg(token, msg);
    }

}
